package com.yingjie.yingjiekitchen.service.impl;

import com.yingjie.yingjiekitchen.mapper.FoodMapper;
import com.yingjie.yingjiekitchen.model.Food;
import com.yingjie.yingjiekitchen.service.FoodService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.ArrayList;

/**
* @author Administrator
* @description 针对表【food(菜品表)】的数据库操作Service实现
* @createDate 2025-03-04 15:46:05
*/
@Service
public class FoodServiceImpl implements FoodService{

    @Resource
    private FoodMapper foodMapper;
    @Override
    public Integer create(Food food) {
        return foodMapper.create(food);
    }

    @Override
    public ArrayList<Food> getFoodListAll(Integer kitchenId) {
        return foodMapper.getFoodListAll(kitchenId);
    }

    @Override
    public Integer modify(Food food) {
        return foodMapper.modify(food);
    }

    @Override
    public Integer delete(Integer foodId) {
        return foodMapper.delete(foodId);
    }
}
